package com.rp.system.po;

import javax.persistence.Entity;
import javax.persistence.Table;

import org.raptor.entity.BaseModel3;


/**
 * 系统模块表
 * @author HuangJian
 *
 */
@Entity
@Table(name="RP_SYSTEM_MODULES")
public class Module extends BaseModel3 {

	private static final long serialVersionUID = 8588302105778524494L;
	
	private String name;
	private String alias;
	private String parentId;
	private String remark;
	
	/**
	 * 资源数量
	 */
	private Integer rescNum = 0;
	
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	
	public String getAlias() {
		return alias;
	}
	public void setAlias(String alias) {
		this.alias = alias;
	}
	
	public String getParentId() {
		return parentId;
	}
	public void setParentId(String parentId) {
		this.parentId = parentId;
	}
	public String getRemark() {
		return remark;
	}
	public void setRemark(String remark) {
		this.remark = remark;
	}
	public Integer getRescNum() {
		return rescNum;
	}
	public void setRescNum(Integer rescNum) {
		this.rescNum = rescNum;
	}
	
	/**
	 * 重写equals方法
	 */
	@Override
	public boolean equals(Object obj) {
		if (obj instanceof Module) {
			Module module = (Module) obj;
			if (module.getId().equals(this.getId())) {
				return true;
			}
		}
		return false;
	}
	
}
